home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part1 / 1009 < prev    next >
Encoding:
Internet Message Format  |  1996-08-06  |  2.0 KB

  1. Path: news.sprintlink.net!datalytics!news
  2. From: Rob Stewart <stew@datalytics.com>
  3. Newsgroups: comp.lang.c++
  4. Subject: Re: Help a newbie Idiot... PLEASE!
  5. Date: 8 Jan 1996 19:46:58 GMT
  6. Organization: Datalytics, Inc
  7. Message-ID: <4crsbi$h4r@gold.datalytics.com>
  8. References: <dilcherDKqG0r.4rE@netcom.com>
  9. NNTP-Posting-Host: pc071.datalytics.com
  10. Mime-Version: 1.0
  11. Content-Type: text/plain; charset=us-ascii
  12. Content-Transfer-Encoding: 7bit
  13. X-Mailer: Mozilla 1.22 (Windows; I; 32bit)
  14.  
  15. dilcher@cueva.com (Jeff Dilcher) wrote:
  16. >I am taking a C class at school, and thought that I would buy a
  17. >compiler to do some of the assignments at home.
  18. >
  19. >I picked up Borland C++ version 4.5, because, on the box it said it
  20. >would handle regular C programming, and I thought that lateron
  21. >I might get into some of the more advanced features.
  22.  
  23. This was right approach.  C++ is an extension to C (there are 
  24. only a few things in C that C++ changes).
  25.  
  26. >I simply want to edit and compile a no frills C program for dos.
  27. >Could someone with this software tell me how to do this?
  28.  
  29. I don't have BC++, but if your files have an extension of .C, 
  30. they will be treated as C and not C++.
  31.  
  32. >  All the
  33. >documentation is geared toward C++, but I am told I can still
  34. >use it for just plain C.  Whenever I start to edit files, they seem
  35. >to default to the Cpp extensions, when I just want to edit 
  36.  
  37. You should be able to do a File|Save As to rename the file 
  38. when you save it.  In fact, doesn't each new file have a name 
  39. like Untitled.cpp or something similar?  When you save it, I 
  40. suspect the IDE will prompt you to supply a better filename.  
  41. When you do that, just give it a .C extension.
  42.  
  43. >and 
  44. >compile simple C programs.
  45.  
  46. You can write straight C code in a .CPP file with impunity.  
  47. The only problem is that the compiler will allow you to do 
  48. things that C++ has added (like function overloading) that is 
  49. not legal C.  Your instructor may not like that.
  50.  
  51. -- 
  52. Robert Stewart        | My opinions are usually my own.
  53. Datalytics, Inc.
  54. (513)226-7700
  55. stew@datalytics.com
  56.  
  57.  
  58.